var express = require('express');
var msbd = require('./msbd.js')
var user = require('./users.js')
var classify = require('./classify.js')
var permissions = require('./permissions.js')
var dashboard = require('./dashboard.js')
var app = express();


app.all('*', function (req, res, next) {
    res.header("Access-Control-Allow-Origin", "*");
    res.header("Access-Control-Allow-Headers", "Content-Type,Access-Token,x-token");
    next()
})
app.get('/upload/*',function(req,res){
	console.log(req.url)
	res.sendFile(__dirname +'/'+req.url)
})


app.use('/msbd', msbd)
app.use('/user', user)
app.use('/classify', classify)
app.use('/permissions', permissions)
app.use('/dashboard', dashboard)


app.listen(1111)
